var static={
	area:[

			[['010','北京','BEIJING'],'-1'],
			[['020','上海','SHANGHAI'],'-1'],
			[['030','天津','TIANJIN'],'-1'],
			[['040','重庆','CHONGQING'],'-1'],
			[['500','广州','GUANZHOU'],'-1'],
			[['510','深圳','SHENZHEN'],'-1']
		 ],
	provinces: 
		[

			['050','广东省','GUANGDONG'],
			['130','海南省','HAINAN'],
			['150','河南省','HENAN'],
			['170','湖北省','HUBEI'],
			['180','湖南省','HUNAN'],
			['060','江苏省','JIANGSU'],
			['070','浙江省','ZHEJIANG'],
			['080','安徽省','ANHUI'],
			['090','福建省','FUJIAN'],
			['200','江西省','JIANGXI'],
			['250','山东省','SHANDONG'],
            ['100','甘肃省','GANSU'],
			['230','宁夏自治区','NINGXIA'],
			['240','青海省','QINGHAI'],
			['270','陕西省','SHANXI'],
			['300','新疆自治区','XINJIANG'],
            ['110','广西自治区','GUANGXI'],
			['120','贵州省','GUIZHOU'],
			['280','四川省','SICHUAN'],
			['290','西藏自治区','XIZANG'],
			['310','云南省','YUNNAN'],
			['140','河北省','HEBEI'],
			['220','内蒙古自治区','NEIMENGGU'],
			['260','山西省','SHANXI'],
			['160','黑龙江省','HEILONGJIANG'],
			['190','吉林省','JILIN'],
			['210','辽宁省','LIAOLING'],
			['320','香港','HONGKONG'],
			['330','澳门','MACAO'],
			['340','台湾','TAIWAN']
/*			['350','其他亚洲国家和地区','Other Asian Countries or Regions'],
			['360','北美洲','North America'],
			['370','南美洲','South America'],
			['380','大洋洲','Oceania'],
			['390','欧洲','Europe'],
			['400','非洲','Africa']*/
	    ],
	city:
		[
			['050',['050020','广州','GUANGZHOU'],['050030','潮州','CHAOZHOU'],
			       ['050040','东莞','DONGGUAN'],['050050','佛山','FOSHAN'],
			       ['050060','惠州','HUIZHOU'],['050070','清远','QINGYUAN'],
			       ['050080','汕头','SHANTOU'],['050090','深圳','SHENZHEN'],
			       ['050100','顺德','SHUNDE'],['050110','湛江','ZHANJIANG'],
			       ['050120','肇庆','ZHAOQING'],['050130','中山','ZHONGSHAN'],
			       ['050140','珠海','ZHUHAI']],
			['060',['060020','南京','NANJIN'],['060030','常熟','CHANGSHU'],
			       ['060040','常州','CHANGZHOU'],['060050','昆山','KUNSHAN'],
		               ['060060','连云港','LIANYUNGANG'],['060070','南通','NANTONG'],
			       ['060080','苏州','SUZHOU'],['060090','太仓','TAICANG'],
		               ['060100','无锡','WUXI'],['060110','徐州','XUZHOU'],
			       ['060120','扬州','YANGZHOU'],['060130','镇江','ZHENJIANG']],
			['070',['070020','杭州','HANGZHOU'],['070030','宁波','NINGBO'],
				   ['070040','温州','WENZHOU'],['070050','绍兴','SHAOXING'],
				   ['070060','金华','JINHUA'],['070070','台州','TAIZHOU'],
				   ['070080','湖州','HUZHOU'],['070090','嘉兴','JIAXING'],
				   ['070100','衢州','QUZHOU'],['070110','丽水','JIAXING'],
				   ['070120','舟山','ZHOUSHAN']],
			['080',['080020','合肥','HEFEI'],['080030','安庆','ANQING'],
				   ['080040','蚌埠','BENGBU'],['080050','芜湖','WUHU']],
			['090',['090020','福州','FUZHOU'],['090030','泉州','QUANZHOU'],
				   ['090040','厦门','XIAMEN'],['090050','漳州','ZHANGZHOU']],
			['100',['100020','兰州','LANZHOU'],['100030','嘉峪关','JIAYUGUAN'],
				   ['100040','酒泉','JIUQUAN']],
			['110',['110020','南宁','NANNING'],['110030','北海','BEIHAI'],
				   ['110040','桂林','GUILIN'],['110050','柳州','LIUZHOU'],
				   ['110060','玉林','YULIN']],
			['120',['120020','贵阳','GUIYANG'],['120030','遵义','ZUNYI']],
			['130',['130020','海口','HAIKOU'],['130030','三亚','SANYA']],
			['140',['140020','石家庄','SHIJIAZHUANG'],['140030','保定','BAODING'],
				  ['140040','承德','CHENGDE'],['140050','邯郸','HANDAN'],
				  ['140060','廊坊','LANGFANG'],['140070','秦皇岛','QINHUANGDAO'],
				  ['140070','唐山','TANGSHAN'],['140080','张家口','ZHANGJIAKOU']],
			['150',['150020','郑州','ZHENGZHOU'],['140030','开封','KAIFENG'],
				  ['150020','洛阳','LUOYANG']],
			['160',['160020','哈尔滨','HAERBING'],['160030','大庆','DAQING'],
				  ['160040','佳木斯','JIAMUSI'],['160050','牡丹江','MUDANJIANG'],
				  ['160060','齐齐哈尔','QIQIHAER']],
			['170',['170020','武汉','WUHAN'],['170030','十堰','SHIYAN'],
				  ['170040','襄樊','XIANGFAN'],['170050','宜昌','YICHANG'],
				  ['170060','潜江','QIANJIANG'],['170070','荆门','JINGMEN'],
				  ['170080','荆州','JINGZHOU'],['170090','黄石','HUANGSHI']],
			['180',['180020','长沙','CHANGSHA'],['180030','湘潭','XIANGTAN'],
				  ['180040','株洲','ZHUZHOU'],['180050','常德','CHANGDE'],
				  ['180060','衡阳','HENGYANG'],['180070','益阳','YIYANG'],
				  ['180080','郴州','CHENZHOU'],['180090','岳阳','YUEYANG']],
			['190',['190020','长春','CHANGCHUN'],['190030','吉林市','JINLINSHI']],
			['200',['200020','南昌','NANCHANG'],['200030','九江','JIUJIANG']],
			['210',['210020','沈阳','SHENYANG'],['210030','鞍山','ANSHAN'],
				  ['210020','大连','DALIAN'],['210030','葫芦岛','HULUDAO']],
			['220',['220020','呼和浩特','HUHEHAOTE'],['210030','包头','BAOTOU'],
				  ['220040','赤峰','CHIFENG']],
			['230',['230020','银川','YINCHUAN']],
			['240',['240020','西宁','XINING']],
			['250',['250020','济南','JINAN'],['250030','德州','DEZHOU'],
				  ['250040','东营','DONGYING'],['250050','济宁','JINING'],
				  ['250060','临沂','LINYI'],['250070','青岛','QINGDAO'],
				  ['250080','日照','RIZHAO'],['250090','泰安','TAIAN'],
				  ['250100','威海','WEIHAI'],['250110','潍坊','WEIFANG'],
				  ['250120','烟台','YANTAI'],['250130','淄博','ZIBO']],
			['260',['260020','太原','TAIYUAN'],['260030','大同','DATONG'],
				  ['260040','临汾','LINFEN'],['260050','运城','YUNCHENG']],
			['270',['270020','西安','XIAN'],['270030','宝鸡','BAOJI'],
				  ['270040','咸阳','XIANYANG']],
			['280',['280010','四川省','SICHUAN'],['280020','成都','CHENGDU'],
				  ['280030','乐山','LESHAN'],['280040','泸州','LUZHOU'],
				  ['280050','绵阳','MIANYANG'],['280060','内江','NEIJIANG'],
				  ['280070','宜宾','YIBIN'],['280080','自贡','ZIGONG']],
			['290',['290010','拉萨','LASA'],['290020','日喀则','RIKAZE']],
			['300',['300020','乌鲁木齐','WULUMUQI'],['300030','喀什','KASHI'],
				 ['300030','克拉玛依','KELAMAYI'],['300040','伊犁','YILI']],
			['310',['310020','昆明','KUNMING'],['300030','大理','DALI'],
				 ['300030','丽江','LIJIANG'],['300040','玉溪','YUXI']],
			['340',['340020','台湾','TAIWAN']]

					//从这里看是添加 其他不要动
		],
	tradecategory:
		[
			['010','IT|互联网|通信|电子'],
			['020','金融|银行|保险'],
            ['030','房地产|建筑建设|物业'],
            ['040','广告|传媒|印刷出版'],
            ['050','消费零售|贸易|交通物流'],
            ['060','加工制造|仪表设备'],
            ['070','能源矿产|石油化工'],
            ['080','专业服务|教育|科研'],
            ['090','医药生物|医疗保健'],
            ['100','服务业']

		],
	trade:
		[
		 	['010',['010010','计算机软件'],['010020','IT服务(系统/数据/维护)/多领域经营'],
				   ['010030','计算机硬件及网络设备'],
				   ['010040','互联网/电子商务'],['010050','网络游戏'],['010060','通信/电信/网络设备'],
				   ['010070','电子技术/半导体/集成电路务']],
			['020',['020010','金融/投资/基金/证券/期货'],['020030','银行'],['020040','保险'],
				   ['020040','房地产|建筑建设|物业']],
            ['030',['030010','房地产/建筑/建材/工程'],['030020','家居/室内设计/装饰装潢'],['030030','物业管理/商业中心'],
				   ['030040','地产代理/营销/策划']],
            ['040',['040010','广告/会展/公关/市场推广'],['040020','媒体/出版/影视/文化/艺术'],['040030','印刷/包装/造纸']],
            ['050',['050010','快速消费品(食品/饮料/烟酒/化妆品)'],['050020','耐用消费品(服装服饰/纺织/皮革/家具/家电)'],['050030','零售/批发'],
				   ['050040','贸易/进出口'],['050050','礼品/玩具/工艺美术/收藏品/奢侈品'],['050060','交通/运输/航空/航天/物流']],
            ['060',['060010','办公用品及设备'],['060020','原材料加工/制造/模具'],['060030','汽车/摩托车(制造/维护/配件/销售/服务)'],
				   ['060040','仪器仪表/工业自动化/电气'],['060050','机械制造·机电·重工'],['060060','检验/检测/认证']],
            ['070',['070010','石油/石化/化工'],['070020','电气/电力/水利'],['070030','矿产/采掘/冶炼'],['070040','新能源']],
            ['080',['080010','咨询/管理/法律/财税/审计/人力资源'],
				   ['080020','中介服务/外包服务'],['080030','教育/培训/考试/认证'],['080040','环保/学术/科研']],
            ['090',['090010','医药/生物工程'],['090020','医疗设备/器械'],['090030','医疗/保健/美容/卫生服务']],
            ['100',['100010','酒店/餐饮'],['100020','旅游/度假'],['100030','娱乐/体育/休闲'],
				   ['100040','政府/非赢利机构/其他'],['100050','政府/公共事业/非盈利机构'],['100060','农/林/牧/渔']],
		],
	jobcategory:
		[
			['020','销售类','Sales Category'],
			['010','经营管理类','Management Category'],
			['100','计算机·网络·技术类','Computer Network Technology Category'],
			['140','金融类','Financial'],
			['060','市场·公关·媒介类','Marketing/Public Relations/ Media Category'],
			['170','建筑·房地产·装饰装修·物业管理类','Architectural/Real Estate/Decoration/Renovation/Property Management'],
			['070','人力资源类','Human Resource Category'],
			['090','财务·审计·统计类','Financial/Auditing/Statistical Category'],
			['040','项目管理类','Project Management'],
			['160','贸易·物流·采购·运输·仓储类','Trade/Transportation/Warehousing/Logistics/Procurement'],
			['210','工厂生产类','Factory Category'],['110','电子·电器·通信技术类','Electrical/Electronics/Communications Technology Category'],
			['240','美术·设计·创意类','Art/Design/Creative Category'],['050','质量管理类','Quality Management'],
			['220','工程·机械·仪器仪表类','Engineering/Machinery/Instrumentation Category'],
			['250','文体·影视·写作·媒体类','Writing/Film and Television/Media Category'],['150','保险类','Insurance Category'],
			['290','生物·制药·化工·环保类','Biopharmaceutical/Chemical Industry/Environmental Protection Category'],
			['080','行政·后勤类','Administrative/Logistical Category'],['130','咨询·顾问类','Consultant Category'],
			['030','客户服务类','Customer Service Category'],['270','法律类','Legal Category'],
			['300','科研类','Research Category'],['280','医疗卫生·美容保健类','Medical/Health and Beauty/Health Products Category'],
			['190','酒店·餐饮·旅游·服务类','Hotel/Restaurant/Tourism/Services'],
			['120','电气·能源·动力类','Electrical Energy and Power'],
			['260','教育·培训类','Education/Training Category'],['291','商业零售业','Commercial Retail'],
			['180','翻译类','Translation Category'],['340','其他类','Other']
		],
	job:[
 			['010',  ['010010','首席执行官CEO·总裁·总经理','President and General Manager/CEO/General Manager'],
					 ['010020','首席运营官COO','Chief Operating Officer/COO'],
					 ['010030','首席技术官CTO·首席信息官CIO','Chief Technology Officer/Chief Information Officer'],
					 ['010040','首席财务官CFO','Chief Financial Officer/CFO'],
					 ['010050','副总裁·副总经理','Vice President/Deputy General Manager'],
					 ['010060','合伙人','Partner'],['010070','总监·事业部总经理','Director/Division General Manager'],
					 ['010080','总裁助理·总经理助理','Executive Assistant/General Manager Assistant'],
					 ['010090','分公司经理·分支机构经理·办事处经理','Branch Manager/Branch Office Manager/Office Manager'],
					 ['010100','部门经理','Department Manager'],['010110','厂长·副厂长','Factory Director/Assistant Factory Director'],
					 ['010120','店长','Manager'],
					 ['010130','其他经营管理类','Other Business Management Category']],
  			['020', ['020005','区域销售总监','Regional Sales Director'],['020010','销售总监','Sales Director'],
					['020020','销售经理·销售主管','Sales Manager/Sales Director'],
					['020025','区域销售经理','Area Sales Manager'],
					['020040','渠道总监·分销总监','Distribution Director/Director of Distribution'],
					['020050','渠道分销经理·渠道分销主管','Distribution Channel Director/Distribution Channel Manager-In-Charge'],
					['020070','售前支持经理·售前支持主管','Pre-Sales Support Manager/Pre-Sales Support Director'],
					['020080','售前支持工程师','Pre-Sales Support Engineer'],
					['020100','商务经理·商务主管','Business Manager/Manager-In-Charge of Commerce'],
					['020120','业务拓展(BD)经理','Business Development Manager'],['020160','其他销售类','Other Sales Category']],
			
 		   ['030',  ['030010','客户服务总监','Director of Customer Service'],
					['030020','客户服务经理·客户服务主管','Customer Service Manager/Customer Service Supervisor'],
					['030040','客户关系管理','Customer Relations Management'],
					['030060','售后支持经理·售后支持主管','After-Sales Support Manager/After-Sales Support Director'],
					['030070','售后支持工程师','Sales Support Engineer'],['030080','其他客户服务类','Other Customer Service Category']],
  			['040', ['040010','项目总监','Project Director'],['040020','项目经理','Project Manager'],['040030','其他项目管理类','Other Project Management']],
  			['050', ['050010','质量保证(QA)·质量管理·质量督导','Quality Assurance/Quality Management/Quality Supervision'],
					['050020','质量控制(QC)·质量检验','Quality Control/Quality Inspection'],['050030','产品测试','Product Testing'],
					['050040','供应商管理·采购设备与材料质量管理','Supply Manager/Procurement/Equipment/Materials/Quality Control Management'],
					['050050','其他质量管理类','Other Quality Management']],
  			['060', ['060010','市场总监CMO','Chief Marketing Officer Director'],
					['060020','市场营销经理·市场营销主管','Marketing Manager, Marketing Director'],
					['060040','公关媒介经理·公关媒介主管','Director of Public Relations/Public Media Manager'],
					['060060','市场调研与分析','Market Research and Analysis'],['060070','会务经理·会务主管','Meetings Manager/Meetings Chair'],
					['060090','产品经理·品牌经理·主管','Product Manager/Brand Manager-In-Charge'],['060110','促销经理·促销主管','Promotions Manager/Promotions Director'],
					['060130','市场企划经理·市场企划主管','Market Planning Manager/Director of Market Planning'],
					['060150','广告创意·策划·设计或文案','Advertising/Creative Planning/Design or Copy'],
					['060170','广告客户经理·广告客户主管','Advertising Account Manager/Advertising Director'],
					['060190','其他市场·公关·媒介类','Other Markets/Public Relations/Media Category']],
  			['070', ['070010','人力资源总监','Director of Human Resources'],
					 ['070020','人力资源经理·人力资源主管','Human Resources Manager/Head of Human Resources'],
					 ['070040','人事主管·人事专员','Personnel Director/Manager-In-Charge of Personnel'],
					 ['070050','招聘经理·招聘主管','Recruitment Manager/Recruitment Director'],['070070','培训经理·培训主管','Training Manager/Training Director'],
					 ['070080','培训师·培训专员·培训助理','Trainer/Training Assistant/Director for Training'],['070100','薪资福利经理·主管','Compensation and Benefits Manager/Director'],
					 ['070120','绩效考核经理·绩效考核主管','Performance Assessment Manager/Performance Assessment Director'],
					 ['070140','员工关系经理·员工关系主管','Employee Relations Manager/Employee Relations Manager'],['070160','其他人力资源类','Other Human Resources']],
 			 ['080', ['080010','行政总监','Executive Director'],['080020','行政经理·行政主管·办公室主任','Executive Management/Director/Office Manager'],
					 ['080060','图书情报·资料·文档管理','Archival/Data/Document Management'],['080080','其他行政·后勤类','Other Administrative Logistics Category']],
  			 ['090', ['090010','首席财务官CFO','Chief Financial Officer/CFO'],
					 ['090020','财务总监','Chief Financial Officer'],
					 ['090030','财务经理','Financial Manager'],
					 ['090040','财务主管·总帐主管','Financial Director/General Accounts Director'],
					 ['090050','会计经理·会计主管','Accounting Manager Accounting Manager'],['090060','会计','Accounting'],
					 ['090080','财务分析经理·财务分析主管','Director of Financial Analysis/Financial Analysis Manager'],
					 ['090090','财务分析员','Financial Analyst'],['090100','成本经理·成本主管','Capital Manager/Capital Director'],
					 ['090110','成本管理员','Capital Manager'],['090120','审计经理·审计主管','Audit Manager/Auditing Director'],
					 ['090130','审计专员·审计助理','Audit Specialist/Assistant Auditing Specialist'],['090140','财务助理·会计助理','Finance Assistant/Accounting Assistant'],
					 ['090150','统计','Statistics'],
					 ['090160','税务经理·税务主管','Tax Manager/Tax Director'],['090170','税务专员·税务助理','Tax Assistant/Tax Specialist'],
					 ['090180','投融资经理·投融资主管','Investment and Finance Manager/Investment and Financing Director'],
					 ['090190','其他财务·审计·统计类','Other Financial/Auditing/Statistics']],
  			['100',  ['100010','首席技术官CTO·首席信息官CIO','Chief Technology Officer/Chief Information Officer'],
					 ['100020','技术总监·技术经理','Technical Director/Technical Manager'],
					 ['100030','信息技术经理·信息技术主管','Manager of Information Technology/Director of Information Technology'],
					 ['100040','信息技术专员','Information Technology Specialist'],['100060','项目经理·项目主管','Project Manager/Project Director'],
					 ['100070','项目执行·协调人员','Project Implementation/Project Coordinator'],['100071','产品经理·品牌经理','Product Manager/Brand Manager'],
					 ['100080','系统分析员','System Analyst'],['100090','研发工程师','Research and Development Engineer'],
					 ['100095','系统架构师·网站架构师','Systems Architect/Internet Architect'],['100100','高级软件工程师','Senior Software Engineer'],
					 ['100110','软件工程师','Software Engineer'],
					 ['100120','互联网软件开发工程师','Internet Software Development Engineer'],['100130','高级硬件工程师','Senior Hardware Engineer'],
					 ['100140','系统集成工程师','Systems Integration Engineer'],['100150','硬件工程师','Hardware Engineer'],
					 ['100170','工程与项目实施','Engineering and Project Implementation'],['100180','ERP应用·ERP实施','ERP Applications/ERP implementation'],
					 ['100190','数据库管理员·数据库开发工程师','Database Administrator/Database Developer Engineer'],
					 ['100200','技术支持·维护经理·维护工程师','Technical Support Engineer/Maintenance Manager/Maintenance Engineer'],
					 ['100220','品质经理·质量工程师','Quality Manager/Quality Engineer'],['100230','网络与信息安全工程师','Network and Information Security Engineer'],
					 ['100235','计量工程师·标准化工程师','Measurement Engineer/Standardization Engineer'],
					 ['100240','软件测试·系统测试','Software Testing/Systems Testing'],['100250','硬件测试','Hardware Testing'],
					 ['100260','文档工程师','Documentation Engineer'],['100270','系统管理员·系统工程师·网管','Network Administrator/System Engineer'],
					 ['100280','语音·视频·图形','Audio/Video/Graphics'],['100290','游戏设计与开发','Game Design and Development'],
					 ['100300','网站营运管理','Web Operations Management'],['100310','网站编辑','Website Editor'],
					 ['100320','网站策划','Site Planning'],['100330','网络工程师','Network Engineer'],
					 ['100340','网页设计·网页制作·网站美工','Web Design/Web Site Graphics Production'],['100350','计算机辅助设计工程师','Computer Aided Design Engineer'],
					 ['100360','其他计算机·网络·技术类','Other Computer Network Technology']],
  			['110',  ['110010','电子工程师·电路工程师','Electronics Engineer/Circuit Engineer'],['110020','电器工程师','Electrical Engineer'],
					 ['110030','电信工程师·通讯工程师','Telecommunications Engineer/Communications Engineer'],
					 ['110040','工艺工程师','Process Engineer'],['110050','电声工程师','Acoustic Engineer'],
					 ['110060','数码产品开发工程师','Digital Product Development Engineer'],
					 ['110065','嵌入式硬件开发','Embedded Hardware Development'],['110070','嵌入式软件开发·电子软件开发','Embedded Software Development/Software Development'],
					 ['110080','无线电工程师','Radio Engineer'],['110090','半导体工程师','Semiconductor Engineer'],
					 ['110100','电子元器件工程师','Electronic Component Engineer'],['110110','电子·电器维修','Electronics/Electronics Repair'],
					 ['110120','光源与照明工程师','Light Source and Lighting Engineer'],['110130','集成电路(IC)芯片开发','Integrated circuit (IC) chip development'],
					 ['110140','技术文档工程师','Technical Documentation Engineer'],['110150','测试工程师','Test Engineer'],['110160','机械工程师','Mechanical Engineer'],
					 ['110170','电气工程师','Electrical Engineer'],['110180','研发工程师','Research and Development Engineer'],
					 ['110190','工程与项目实施','Engineering and Project Implementation'],
					 ['110200','其他电子·电器·通信技术类','Other Electrical/Electronics/Communications Technology Category']],
  			['120',  ['120010','电气工程师','Electrical Engineer'],['120020','光源与照明工程','Lamps and Lighting Engineering'],
					 ['120030','变压器与磁电工程师','Transformers and Magnetic Power Engineers'],['120040','电路工程师','Circuitry Engineer'],
					 ['120050','智能大厦·综合布线·弱电','Intelligent Building/Integrated Wiring/Low-Voltage Electric'],['120060','电力工程师','Power Engineer'],
					 ['120070','电气维修技术员','Electrical Maintenance Technician'],['120080','水利·水电工程师','Water Resources/Water and Electric Engineer'],
					 ['120090','核力·火力工程师','Nuclear Power/Fire Engineer'],['120100','空调·热能工程师','Air-Conditioning/Energy Engineers'],
					 ['120110','石油天然气技术人员','Oil and Natural Gas Technicians'],['120120','自动控制','Automatic Controls'],
					 ['120130','制冷·暖通','HVAC/Refrigeration'],['120140','其他电气·能源·动力类','Other Electrical/Energy/Power']],
 			['130',  ['130010','企管顾问·专业顾问·策划师','Business Management/Consultant/Adviser/Professional Planner'],
					 ['130020','咨询总监','Advisory Director'],['130030','咨询经理','Managing Consultant'],
					 ['130040','咨询员','Consultants'],['130050','调研员','Researcher'],['130060','培训师','Trainers'],
					 ['130070','涉外咨询师','Foreign Consultants'],['130080','其他咨询·顾问类','Other Consultant Category']],
			['140',	['140010','证券·外汇·期货经纪人','Securities/Foreign Exchange/Futures/Brokerage'],
					  ['140020','行长·副行长·高级管理','President Vice President Senior Management'],
					  ['140030','投资·证券·操盘·基金·理财','Investment/Securities/Trader/Money Fund '],
					  ['140040','投资银行业务','Investment Banking'],['140050','融资项目管理','Financial Project Management'],
					  ['140060','客户经理·金融产品营销管理','Client Manager/Financial Product Marketing Manager'],
					  ['140070','资产管理·资产评估·交易管理','Transaction Management/Asset Management/Asset Evaluation'],
					  ['140080','风险管理·稽核·法律','Risk Management/Auditing/Legal'],['140090','信贷管理·信用管理','Credit Management/Credit Management'],
					  ['140100','资金管理·财务管理·清算·结算','Fund Management/Financial Management/Liquidation/Settlement'],
					  ['140110','柜员·理财咨询·客户服务·银行会计','Bank Teller/Banking Consulting/Customer Service/Accounting'],
					  ['140120','银行卡·电子银行·新业务开拓','Bank card/Electronic Banking/New Business'],
					  ['140130','国际结算·外汇交易','International Account Settlement/Foreign Exchange'],
					  ['140135','拍卖师','Auctioneer'],['140140','其他金融类','Other Financial']],
			['150',  ['150010','精算·产品研发·投资·稽核·法律','Auditing/Research and Development/Investment/Law'],
					  ['150020','核保·理赔·契约管理·受理台','Underwriting/Claims/Contract Management/Receiving Desk'],
					  ['150030','组训·培训·人员管理·业务推动','Organizational Training/Personnel Training/Management Services/Business Promotion'],
					  ['150040','保险代理人·经纪人·客户经理','Insurance Agent/Broker/Account Manager'],
					  ['150050','客户服务·续期管理','Customer Service/Account Renewals Management'],
					  ['150060','其他保险类','Other Insurance']],
			['160', ['160010','外贸经理·主管·专员·助理','Trade Manager/Director/Foreign Trade Manager'],
					 ['160020','国内贸易经理·主管·专员·助理','Assistant Manager/Director/Domestic Trade Manager'],
					 ['160021','商务经理·主管·专员·助理','Business Manager/Director/Specialist/Assistant'],
					 ['160040','单证员·报关员','Document Management/Customs Agent'],['160050','海运·空运操作人员','Shipping/Air Freight Operator'],
					 ['160070','采购总监·经理·主管','Purchasing Executive/Manager/Director'],
					 ['160090','物流总监·经理·主管','Logistics Executive/Manager/Director'],
					 ['160095','供应链总监·经理·主管','Supply Chain Executive/Manager/Director'],
					 ['160110','物料管理','Materials Management'],['160120','仓库管理','Warehouse Management'],
					 ['160130','运输经理·主管','Transport Management/Executive'],['160140','货运代理','Freight Forwarder'],
					 ['160150','海陆空交通运输','Sea and Air Transport'],
					 ['160160','调度员','Controller'],['160180','其他贸易·物流·采购·运输·仓储类','Other Trade/Logistics/Procurement/Transport/Storage']],
  			['170',  ['170010','建筑师','Architect'],['170020','结构工程师·土木土建工程师','Structural Engineer/Civil Engineer'],
					 ['170030','建筑设计·建筑制图','Architectural Design/Architectural Drawing'],['170040','建筑工程管理','Construction Management'],
					 ['170050','工程监理','Project Management'],['170060','给排水·强电·弱电·制冷暖通','Liquid Cooling/High Voltage Power/Low Voltage Power/HVAC'],
					 ['170070','房地产开发·策划','Real Estate Development/Planning'],['170080','房地产评估','Real Estate Appraisal'],
					 ['170090','设备工程师','Equipment Engineer'],['170100','造价·概预算','Costing/Budget Estimation'],
					 ['170110','路桥·隧道·港口·航道工程','Road/Bridge/Tunnel/Port/Channel Engineering'],
					 ['170120','园艺设计·园林设计·景观设计','Garden Design/Landscape Design'],['170130','室内外装潢设计','Indoor and Outdoor Decoration Design'],
					 ['170140','物业管理','Property Management'],['170150','城市规划与设计','Urban Planning and Design'],
					 ['170160','房地产中介·交易','Real Estate Brokerage/Transactions'],
					 ['170170','公路桥梁设计·公路桥梁预算师','Road and Bridge Design/Highway and Bridge Budgeting'],
					 ['170180','施工员','Construction Worker'],['170190','其他','Other']],
		    ['180',  ['180010','英语','English'],['180020','日语','Japanese'],['180030','法语','French'],
					 ['180040','德语','German'],['180050','俄语','Russian'],['180060','西班牙语','Spanish'],['180070','朝鲜语','Korean'],
					 ['180080','其他语种翻译','Other Languages Translation']],
 			['190',  ['190010','宾馆或酒店管理','Hotel or Hotel Management'],
					 ['190020','娱乐或餐饮管理','Entertainment or Food and Beverage Management'],
					 ['190030','大堂经理·副理','Lobby Manager/Assistant Manager'],['190040','楼面经理','Floor Manager'],
					 ['190050','厨师·调酒师·茶艺师','Chef/Bartender/Tea Service'],['190060','营养师','Dietitian'],
					 ['190100','导游','Guide'],['190110','健身教练','Fitness Coach'],['190120','美容美发','Beauty Salon'],
					 ['190170','其他酒店·餐饮·旅游·服务类','Other Hotel/Restaurant/Tourism/Services']],
			['210',  ['210015','营运经理·营运主管','Operations Manager/Operations Director'],
					 ['210020','总工程师·副总工程师','Chief Engineer/Deputy Chief Engineer'],
					 ['210030','技术工程师·项目工程师·产品工程师','Technical Engineer/Project Engineer/Product Engineer'],
					 ['210040','采购管理','Purchasing Management'],['210050','物料或物流管理','Materials or Logistics Management'],
					 ['210060','工程或设备管理','Engineering or Equipment Management'],['210070','安全·健康·环境管理','Safety/Health/Environmental Management'],
					 ['210080','产品开发','Product Development'],['210090','技术或工艺设计经理','Technology or Process Design Manager'],
					 ['210110','化验·检验','Laboratory/Testing'],['210120','仓库管理','Warehouse Management'],
					 ['210130','维修工程师','Maintenance Engineer'],['210140','生产经理·车间主任·生产主管','Production Manager/Workshop Director/Production Supervisor '],
					 ['210150','组长·拉长','Group Leader/'],['210160','生产计划·调度','Production Planning/Scheduling'],
					 ['210170','产品或生产工艺工程师(PE·ME)','Product or Production Process Engineer'],['210180','工业工程师（IE）','Industrial Engineer'],
					 ['210190','制造工程师','Manufacturing Engineer'],['210200','其他工厂生产类','Other Factory Class']],
  			['220', ['220005','工程/设备·主管·经理·工程师','Engineering/Equipment/Director/Manager'],
					 ['220010','机械工程师·工业工程师·结构工程师','Mechanical Engineers/Industrial Engineers/Structural Engineers'],
					 ['220020','模具工程师','Mold Engineer'],['220030','机械设计师','Mechanical Designer'],['220040','机械制图员','Mechanical Draftsman'],
					 ['220050','机电工程师','Electrical and Mechanical Engineers'],
					 ['220060','精密机械·仪器仪表工程师·技术员','Precision Instrumentation/Instrumentation Engineer/Mechanical Technician'],
					 ['220070','铸造·锻造工程师','Casting/Forging Engineer'],['220080','注塑工程师','Injection Engineers'],['220090','CNC工程师','CNC Engineer'],
					 ['220100','冲压工程师','Stamping Engineer'],['220110','夹具工程师','Fixture Engineer'],['220120','锅炉工程师','Boiler Engineer'],
					 ['220130','焊接工程师','Welding Engineer'],['220140','汽车·摩托车工程师','Automobile/Motorcycle Engineer'],
					 ['220150','船舶工程师','Ship Engineer'],['220160','飞行器设计与制造','Aircraft Design and Manufacturing'],
					 ['220170','机械维修工程师','Mechanical Maintenance Engineer'],['220180','包装·印刷','Packaging/Printing'],
					 ['220190','食品机械','Food Machinery'],['220200','纺织机械','Textile Machinery'],
					 ['220210','设备修理','Equipment Repair'],['220220','其他工程·机械·仪器仪表类','Other Construction/Machinery/Instrumentation Category']],
			['240', ['240010','设计管理人员','Design Management'],['240020','美术·图形设计','Art/Graphic Design'],
					['240030','工业·产品设计','Industrial/Product Design'],['240040','服装·纺织品设计师','Clothing/Textile Designer'],
					['240050','服装打样·服装制板','Apparel Proofing/Clothing Patterning'],['240060','工艺品·珠宝设计','Crafts/Jewelry Design'],
					['240070','家具设计','Furniture Design'],['240080','平面设计','Graphic Design'],['240090','媒体广告设计','Media Advertising'],
					['240100','造型设计','Modeling Design'],['240110','多媒体设计','Multimedia Design'],['240120','动画·3D设计','Animation/3D Design'],
					['240125','包装设计','Packaging Design'],['240130','展示·装潢设计','Displays/Interior Design'],
					['240150','其他美术·设计·创意类','Other Art/Design/Creative Category']],
			['250', ['250010','作家·撰稿人','Author/Writer'],['250020','总编·副总编','General Editor/Deputy Editor'],
					['250030','编辑·记者·作家·撰稿人','Editor/Reporter/Novelist/Writer'],['250040','美术编辑','Art Editor'],
					['250050','发行总监·经理·主管','Copy Executive/Manager/Writer'],['250060','出版·发行','Publishing/Copy'],
					['250070','校对·录入','Proofreading/Copy Entry'],['250080','排版设计','Layout Design'],
					['250090','艺术总监·设计总监','Artistic Director/Design Director'],
					['250100','影视策划·影视制作','Television or Film Planning/Television or Film Production'],
					['250110','导演·编导','Director/Choreographer'],['250120','摄影·摄像','Photographer/Videographer'],
					['250130','录音·音效师','Recording/Audio Engineer'],['250140','化妆师·造型师','Makeup Artist/Stylist'],
					['250150','演员·配音·模特','Actor/Voice Actor/Model'],['250160','主持人·播音员·DJ','Host/Broadcaster/DJ'],
					['250170','演艺或体育经纪人','Performing Arts or Sports Agent'],['250180','其他文体·影视·写作·媒体类','Other Media/Television and Film/Writing Category']],
			['260', ['260010','教学·教务管理人员','Teaching/Educational Administration'],['260020','幼儿教育','Early Childhood'],
					['260030','教师·教授','Teacher/Professor'],['260040','讲师','Lecturer'],['260050','助教','Teaching assistant'],
					['260070','健身顾问/教练','Fitness Consultant/Coach'],['260080','其他教育·培训类','Other Education/Training Category']],
 			['270', ['270010','律师·律师助理','Lawyer/Paralegal'],['270020','法律顾问','Legal Adviser'],
					['270040','法务人员','Legal Personnel'],['270050','其他法律类','Other Legal Category']],
 			['280', ['280010','医疗管理人员','Medical Management'],['280020','医疗技术人员','Medical Technicians'],
					['280030','医生·医师·理疗师','Surgeon/Doctor/Physical Therapist'],['280050','医药检验','Medical Examiner'],
					['280070','药学技术与管理人员','Pharmaceutical Technology and Management'],['280080','疾病控制·公共卫生','Disease Control/Public Health'],
					['280090','美容·整形师','Beautician/Plastic Surgeon'],['280100','兽医·宠物医生','Veterinarian/Pet Doctor'],
					['280110','药库主任·药剂师','Drug Storehouse Director/Pharmacist'],['280120','针灸推拿','Acupuncture and Massage'],
					['280130','药品注册','Drug Registration'],['280150','医药代表','Medical Representative'],
					['280160','其他医疗卫生·美容保健类','Other Medical/Health and Beauty/Health Products Category']],
			['290', ['290010','生物工程·生物制药','Biopharmaceutical/Biotechnology'],
					 ['290020','临床试验·药品注册·设备注册','Clinical Trial Registration/Drug Registration/Equipment Registration'],
					 ['290030','医药研发·化学制剂研发·医疗设备生产','Pharmaceutical R & D research and development of medical equipment of chemical agents'],
					 ['290040','药品生产·质量管理','Drug Manufacturing/Quality Management'],
					 ['290050','药品销售·推广·业务咨询','Drug Sales/Promotion/Business Consulting'],
					 ['290055','医疗器械推广·销售·维修','Medical Equipment Promotion/Sales/Maintenance'],
					 ['290060','化工技术','Chemical Technology'],['290070','环保技术','Environmental Technology'],
					 ['290080','其他生物·制药·化工·环保类','Other Biopharmaceutical/Chemical Industry/Environmental Protection Category']],
  			['291', ['291010','店长','Manager'],['291020','营运','Operations'],
					['291030','生鲜·防损技术人员','Pharmaceutical R & D research and development of medical equipment of chemical agents'],
					['291031','其他商业零售类','Other Commercial Retail']],
  			['300', ['300010','科研管理人员','Research Management'],
					['300020','科研人员','Researchers'],
					['300030','其他科研类','Other Research Category']],
  			['340', ['340010','航空航天','Aerospace'],['340015','飞机机长·副机长','Captain/Co-Pilot'],
					['340018','列车车长·列车司机','Train Driver'],['340020','安全消防','Fire Safety'],
					['340030','声光学技术·激光技术','Acoustic Laser/Optical Technology'],
					['340040','测绘技术','Mapping Technology'],['340050','地质矿产冶金','Metallurgical Geology and Mineral Resources'],
					['340060','气象','Meteorological'],['340070','农林牧渔','Animal Husbandry and Fishery'],['340080','其他类别职位','Other Job Categories']]
		]
};
$(function(){
	
	function Selinput(){
		this.config=Selinput._default;
		this.templates=Selinput._templates;
	};
	Selinput.prototype={
		mergeObject:function(_obj){
			var obj={};
            for(var attr in this.config){
                obj[attr]=_obj[attr]||this.config[attr];  
            }
			switch(_obj["name"]){
				case "trade":
					obj["data"]=[static.tradecategory,static.trade];
					break;
				case "area":
					obj["data"]=[static.area,static.provinces,static.city];
					break;
				case "job":
					obj["data"]=[static.jobcategory,static.job];
					break;
			}
			return obj;
        },
		bindArea:function(obj){
			this.str_result='<li name="#result#">#name#<em></em></li>';
			this.top=$(this.templates.areashow);
			this.objcity=$(this.templates.city);

			var value=obj.val();
			if(value!=""){
				obj.temp=[];
				obj.temp=value.split(",");
			}
			this.area_index=0;
			this.bindAreaRoot(obj);
			
		
		},
		bindAreaRoot:function(obj){
			var arr=this.config.data[0],
				_temp=[],
				target=this.top.find("ul.area"),
				_this=this;
			for(var i in arr){
				_li=this.templates.childli;
				_li=_li.replace(/#id#/,arr[i][0][0]);
				_li=_li.replace(/#name#/,arr[i][0][1]);
				_li=_li.replace(/#type#/,this.config.seltype);
				if(obj.temp){
					for(var q in obj.temp){
						if(obj.temp[q]==arr[i][0][0]){
							_li=_li.replace(/#checked#/,"checked");	
						}
					}
				}
				_temp.push(_li);
				if(i==arr.length-1){
					break;
				}
			}
			var _temp_li=$(_temp.join(""));
			target.append(_temp_li);
			_temp_li.find("input").bind("click",function(){
				if(_this.config.seltype=="radio"){
					_this.top.find("ul.check_result").empty();
				}
				if($(this).is(":checked")){
					_this.top.find(".control").show();
					var tmphtml=_this.str_result.replace(/#result#/,$(this).val());
						tmphtml=tmphtml.replace(/#name#/,$(this).get(0).nextSibling.nodeValue);
						_tmpthis=$(this);
						
					var _temp=$(tmphtml);
					_temp.bind("click",function(){
						var result=	_temp.attr("name");
						_this.top.find("ul.area input").each(function(){
							if($(this).val()==result){
								$(this).attr("checked",false);
							}
						})					
						$(this).remove();
						_this.show_result();
						if(_this.top.find("ul.check_result li").length==0){
							_this.top.find(".control").hide();
						}
					});
					_this.top.find("ul.check_result").append(_temp);
				}else{
					var li=_this.top.find("ul.check_result li"),
						value=$(this).val();
					li.each(function(){
						if($(this).attr("name")==value){
							$(this).remove();
						}
					});
				}
				if(_this.top.find("ul.check_result li").length==0){
						_this.top.find(".control").hide();
				}
				_this.show_result();
			})
			_this.init_province_html(obj);
		},
		//控制热门地区是显示
		show_result:function(){
			var len=this.top.find("ul.check_result li").length;
			if(len==this.config.maxlength){
				this.top.find("ul.area input:not(:checked)").attr("disabled","true");
			}else{
				this.top.find("ul.area input:not(:checked)").removeAttr("disabled");
			}
		},
		init_province_html:function(obj){ //初始化省html
			var arr=this.config.data[1],
				_this=this,
				count=0,
				target=this.top.find("ul.province").empty(),
				_arr=[],
				citylist=this.objcity.find("ul.citylist"),
				cityall=this.objcity.find("ul.cityall"),
				_temp=arr[0][0];
			if(obj.temp){
				//给编辑的项 加上删除自己说事件		
				_this.top.find(".control").css("display","block");
				for(var s=0;s<obj.temp.length;s++){
					var value=obj.temp[s];
					var tmphtml=_this.str_result.replace(/#result#/,value);
					tmphtml=tmphtml.replace(/#name#/,this.getAreaname(value));
					var _temp=$(tmphtml);
					_this.top.find("ul.check_result").append(_temp);
					_this.show_result();
					(function(value){//比宝
						_temp.bind("click",function(){
							var obj=_this.top.find("ul.area li input");
							obj.each(function(){
								if($(this).val()==value){
									$(this).attr("checked",false);
									return false;
								}
							});
							$(this).remove();
							_this.show_result();
							if(_this.top.find("ul.check_result li").length==0){
								_this.top.find(".control").hide();
							}
						});	
					})(value)
			
				}
			
			}
			//加载省份的html
			for(var i in arr){
				_li=this.templates.parentli;
				_li=_li.replace(/#id#/,arr[i][0]);
				_li=_li.replace(/#name#/,arr[i][1]);
				if(obj.temp){
					for(var q in obj.temp){
						if(obj.temp[q]==arr[i][0]){
							_this.area_index=i;
							_li=_li.replace(/#class#/,'class="current"');
						}
					}
				}
				_arr.push(_li);
			}
			var _temp_li=$(_arr.join(""));
			target.append(_temp_li);
			_temp_li.bind("click",function(){														
				var code=$(this).attr("code");
					_this.bindAreachid(code,obj);
					__this=this;
				$.dialog({
					title:"请选择",
					lock:true,
					padding:"15px 15px 0px 15px",
					content:_this.objcity.get(0),
					okValue:"确定",
					ok:function(){
						if(cityall.find("input:checked").length==0&&citylist.find("input:checked").length==0){
							return;
						}
						_temp_li.get(_this.area_index).className="";
						$(__this).addClass("current");
						_this.area_index=_temp_li.index($(__this));	
					}
				})
			})
		},
		//最核心的东西都在这
		bindAreachid:function(code,obj){
			var arr=this.config.data[2],
				count=0,
				_temp=[],
				_this=this,
				target=this.objcity.find("ul.citylist").empty(),
				check=this.objcity.find("ul.cityall").empty(),
				result=this.top.find("ul.check_result");
				rootcity=this.top.find("ul.area"),
			 	check_li=this.templates.childli,
				check_li=check_li.replace(/#id#/,code),
				check_li=check_li.replace(/#name#/,"不限"),
				check_li=check_li.replace(/#type#/,"checkbox");
				if(result.find("li").length>0){
					result.find("li").each(function(){
						if($(this).attr("name")==code){
							check_li=check_li.replace(/#checked#/,"checked");
							return false;
						}
					});
				}
			var tmp_obj=$(check_li);
			check.append(tmp_obj);//全选按钮
			for(var i in arr){
				if(arr[i][0]==code){
					for(var k=1;k<arr[i].length;k++){
						_li=this.templates.childli;
						_li=_li.replace(/#id#/,arr[i][k][0]);
						_li=_li.replace(/#name#/,arr[i][k][1]);
						_li=_li.replace(/#type#/,this.config.seltype);
						_temp.push(_li);
					}
					break;
				}
			}
			target.append($(_temp.join("")));
			if(check.find("input").is(":checked")){
				target.find("input").attr("disabled","true");
			}else{
				if(result.find("li").length>0){
					result.find("li").each(function(){
						temp_this=$(this);
						target.find("input").each(function(){
							if(temp_this.attr("name")==$(this).val()){
								$(this).attr("checked","true");
								check.find("input").attr("disabled","true");
							}									 
						});
					});
					
				}
			}
			if(result.find("li").length==this.config.maxlength){
				this.objcity.find("input:not(:checked)").attr("disabled","true");
			}
			check.find("input").bind("click",function(){
				if(_this.config.seltype=="radio"){
					_this.top.find("ul.check_result").empty();
				}
				if($(this).is(":checked")){
					_this.top.find(".control").show();
					var value=$(this).val();
					var tmphtml=_this.str_result.replace(/#result#/,value);
					tmphtml=tmphtml.replace(/#name#/,_this.getAreaname(value));
					_tmpthis=$(this);
					var _temp=$(tmphtml);
					_this.top.find("ul.check_result").append(_temp);
					target.find("input:not(:checked)").attr("disabled","true");//点击全选的时候,城市变灰
					if(result.find("li").length==_this.config.maxlength){
						_this.top.find("input:not(:checked)").attr("disabled","true");
					}else{
						_this.top.find("input:not(:checked)").removeAttr("disabled");
					}
					_temp.bind("click",function(){
						$(this).remove();
						_tmpthis.attr("checked",false);
						_this.show_result();
						if(result.find("li").length==0){
							_this.top.find(".control").hide();
						}
					});
				}else{
					var li=result.find("li");
					var value=$(this).val();
					li.each(function(){
						if($(this).attr("name")==value){
							$(this).remove();
						}
					});
					if(result.find("li").length<_this.config.maxlength){
						target.find("input:not(:checked)").removeAttr("disabled");
					}
					if(result.find("li").length==0){
						check.find("input:not(:checked)").removeAttr("disabled");
						_this.top.find(".control").hide();
					}
				}
			});
			target.find("input").bind("click",function(){
				if(_this.config.seltype=="radio"){
					_this.top.find("ul.check_result").empty();
				}
				if($(this).is(":checked")){
					_this.top.find(".control").show();
					var tmphtml=_this.str_result.replace(/#result#/,$(this).val());
					tmphtml=tmphtml.replace(/#name#/,_this.getAreaname($(this).val()));
					_tmpthis=$(this);
					var _temp=$(tmphtml);
					_this.top.find("ul.check_result").append(_temp);
					check.find("input:not(:checked)").attr("disabled","true");//点击城市的时候,全选变灰
					if(result.find("li").length==_this.config.maxlength){
						_this.top.find("input:not(:checked)").attr("disabled","true");
					}else{
						_this.top.find("input:not(:checked)").removeAttr("disabled");
					}
					_temp.bind("click",function(){
						$(this).remove();
						_tmpthis.attr("checked",false);
						if(result.find("li").length==_this.config.maxlength){
							_this.top.find("input:not(:checked)").attr("disabled","true");
						}else{
							_this.top.find("input:not(:checked)").removeAttr("disabled");
						}
						if(result.find("li").length==0){
							_this.top.find(".control").hide();
						}
					});
					if(result.find("li").length==_this.config.maxlength){
						target.find("input:not(:checked)").attr("disabled","true");
					}
				}else{
					var li=_this.top.find("ul.check_result li"),
						value=$(this).val();
					li.each(function(){
						if($(this).attr("name")==value){
							$(this).remove();
						}
					});
					if(result.find("li").length<_this.config.maxlength){
						target.find("input:not(:checked)").removeAttr("disabled");
						check.find("input:not(:checked)").removeAttr("disabled");
					}
					if(result.find("li").length==0){
						check.find("input:not(:checked)").removeAttr("disabled");
						_this.top.find(".control").hide();
					}
				}
				
			});
		},
		getparentindex:function(code){
			for(var i in this.config.data[0]){
				if(this.config.data[0][i][0]==code){
					return i;
				}
			}
		},
		getAreaname:function(str){
			var array=this.config.data[0],
				array1=this.config.data[1],
				array2=this.config.data[2],
				name="";
			if(str.length==3){
				for(var i in array){
					
					if(array[i][0][0]==str){
						return array[i][0][1];
						break;
					}
				}
				for(var j in array1){
					if(array1[j][0]==str){
						return array1[j][1];
					}
				}
			}else{
				for(var m in array1){
					if(array1[m][0]==str.substring(0,3)){
						name=array1[m][1];
						break;
					}
				}
				for(var n in array2){
					if(array2[n][0]==str.substring(0,3)){
						for(var l=1;l<array2[n].length;l++){
							if(array2[n][l][0]==str){
								return name+"-"+array2[n][l][1];
							}
						}
					}
				}
			}
		},
		bindParentlist:function(obj){
		
			if(this.config.name=="area"){
				this.bindArea(obj);
				return;
			}
			if(obj.val()!=""){
				obj.temp=[];
				var code=this.getparentindex(obj.val().substring(0,3));
				obj.temp.push(code,obj.val().split(","));
			}
			var index=typeof obj.temp=="undefined"?0:obj.temp[0];
			this.parent_index=index;
			this.top=$(this.templates.show);
			this.result=this.top.find(".cols:eq(1)");
			var	result = this.top.find(".selector_title"),
				p_List = this.top.find(".cols:first").find("ul"),
				cur_array=this.config.data[0],
				_temp=[],_li="";
			for(var i in cur_array){
				_li=this.templates.parentli;
				_li=_li.replace(/#id#/,cur_array[i][0]);
				_li=_li.replace(/#name#/,cur_array[i][1]);
				_temp.push(_li);
			}
			var _temp_p=$(_temp.join(""));
				_this=this;
			p_List.append(_temp_p);
			_temp_p.eq(this.parent_index).addClass("current");
			_temp_p.bind("click",function(){
				_temp_p.get(_this.parent_index).className="";
				$(this).addClass("current");
				_this.parent_index=_temp_p.index($(this));
				_this.bindChildlist($(this).attr("code"),obj);
				
			});
			
			_this.bindChildlist(this.config.data[0][index][0],obj);
		},
		getData:function(){
			var  result=[];
			if(this.config.name=="area"){
				var obj=this.top.find(".check_result li");
				obj.each(function(){
					result.push($(this).attr("name"));
				});
				return result;
			}
			var _input=this.result.find("input");
			_input.each(function(){
					if($(this).is(":checked")){
			//var _temp=[$(this).val(),$(this).get(0).nextSibling.nodeValue];
						var _temp=$(this).val();
						result.push(_temp);
					}
				}
			 )
			return result;
		},
		//绑定list
		bindChildlist:function(code,obj){
			var cur_array=this.config.data[1],
				target=this.result.find("ul").empty(),
				_temp=[];
			for(var i in cur_array){
				if(cur_array[i][0]==code){
					var arr_select=[];
					for(var k=1;k<cur_array[i].length;k++){
						_list=this.templates.childli;
						_list=_list.replace(/#id#/,cur_array[i][k][0]);
						_list=_list.replace(/#name#/,cur_array[i][k][1]);
						_list=_list.replace(/#type#/,this.config.seltype);
						if(typeof obj.temp!="undefined"&&obj.temp[1]){
							 for(var l in obj.temp[1]){
								if(cur_array[i][k][0]==obj.temp[1][l]){
									_list=_list.replace(/#checked#/,"checked");
								}
							 }
						}
						_temp.push(_list);
					}
					target.append($(_temp.join("")));
					break;
				}
			}
			if(typeof obj.temp!="undefined"&&obj.temp[1]&&obj.temp[0]==this.parent_index){
				if(obj.temp[1].length>=this.config.maxlength){
					target.find("input:not(:checked)").attr("disabled","true");
				}else{
					$(this).find("input:not(:checked)").removeAttr("disabled");
				}
			}
			target.bind("click",function(){
				var len=target.find("input:checked").length;
				if(len>=_this.config.maxlength){
					$(this).find("input:not(:checked)").attr("disabled","true");
				}else{
					$(this).find("input:not(:checked)").removeAttr("disabled");
				}
			});
		},
		//获取父name
		getParent_name:function(code){
		
			var index=0;
			if(this.config.name=="area"){
				index=1;
			}
			var cur_array=this.config.data[index];
			for(var i in cur_array){
				if(cur_array[i][0]==code){
					return cur_array[i][1];
				}
			}
			index--;
			var cur_array0=this.config.data[index];
			for(var m in cur_array0){
				if(cur_array0[m][0][0]==code){
					return cur_array0[m][0][1];
				}
			}
		},
		//获取字name
		getChild_name:function(code){
			var _l=this.config.data.length;
				 cur_array=this.config.data[_l-1],
			    _temp=[];
			for(var i in cur_array){
				if(cur_array[i][0]==code.substring(0,3)){
					_temp=cur_array[i];
					break;
				}
			}
			for(var k=1;k<_temp.length;k++){
				if(_temp[k][0]==code){
					return _temp[k][1];
					break;
				}
			}
		},
		//显示
		showDlg:function(obj){
			var _input=obj,
				_this=this;
				_this.bindParentlist(obj);
			$.dialog({
				title:"请选择",
				lock:true,
				padding:"15px 15px 0px 15px",
				content:this.top.get(0),
				okValue:"确定",
				cancelValue:"取消",
				cancel:function(){
				},
				ok:function(){
					var sel_data=_this.getData();
					_input.val(sel_data.join(","));
					_this.edit_style(_input);
				}
			})
		},
		//编辑时候的样式
		edit_style:function(obj){
			if(obj.val()==""){
				return;
			}
			var list=obj.val().split(","),
				li='<li name="#result#">#name#<em></em></li>',
				_p= obj.parent(),
				result =_p.find(".pop_selection_result").empty().addClass("pop_selection_hide"),
				modify = _p.find(".pop_selection_modify").addClass("pop_selection_hide"),
				selection =_p.find(".pop_selection").addClass("pop_selection_hide");
			for(var i in list){
				var _li=li.replace(/#result#/,list[i]);
				if(list[i].length==3){
					var _p_name=this.getParent_name(list[i]);
				}if(list[i].length==6){
					var _p_name=this.getChild_name(list[i]);
				}
				_li=_li.replace(/#name#/,_p_name);
				$(_li).appendTo(result);
					
			}
			modify.removeClass("pop_selection_hide");
    		result.removeClass("pop_selection_hide");
			result.find("em").bind("click",function(){
				var index=result.find("em").index(this);
				list.splice(index,1);
				obj.val(list.join(","));
				obj.temp=[];
				obj.temp.push(this.parent_index,list);
				$(this).parents("li").remove();
				if(obj.val()==""){
					delete obj["temp"];
					modify.addClass("pop_selection_hide");
					result.addClass("pop_selection_hide");
					obj.parent().find(".pop_selection").removeClass("pop_selection_hide");
				}
				
			})
		}
	};
	Selinput._templates={
		select:'<span class="pop_selection input-text"><em class="icon_selection"><a href="javascript:;"></a></em></span>',
		modify:'<a class="pop_selection_modify" href="javascript:;">修改</a>',
		result:'<ul class="pop_selection_result input-text pop_selection_inline_block"></ul>',
		parentli:'<li code="#id#" #class#><a href="javascript:;">#name#</a></li>',
		childli:'<li><label><input class="inall" #checked# type="#type#" name="scjobs" value="#id#"/>#name#</label></li>',
		show:'<div class="pop_cols_selector job-cols-list">'
+	      '<div class="selector_title">'
+	           '<strong></strong>'
+	           '<ul></ul>'
+	      '</div>'
+	      '<div class="col-list clearfix">'
+	          '<div class="cols"><h2>一级分类</h2><ul></ul></div>'
+	          '<div class="cols"><h2>二级分类</h2><ul></ul></div>'
+	     '</div>',
		areashow:'<div id="sw_area">'
+			'<ul class="area"></ul>'
+			'<ul class="province"></ul>'
+			'<div class="control"><h2>已选择</h2><ul class="check_result"></ul></div></div>',
		city:'<div id="city">'
+			 '<ul class="cityall"></ul>'
+			 '<ul class="citylist"></ul></div>'
	};
	Selinput._default={
		"seltype":"checkbox",
		"all":true,
		"maxlength":2,
		"data":[],
		"name":"-1"   //trade行业  area地区  //工种  
	};
	(function(fyx){
		fyx.fn.bindselect=function(obj){
				var	_obj=new Selinput,
					select=_obj.templates.select,
				    modify=_obj.templates.modify,
				    result=_obj.templates.result;
					_obj.config=_obj.mergeObject(obj);
			this.each(function(){
				var _this=$(this), 
					_select=$(select).insertAfter(_this).width(_this.width()).bind("click",function(){_obj.showDlg(_this)}),
					_result=$(result).insertAfter(_select).addClass("pop_selection_hide"),
					_modify=$(modify).insertAfter(_result).addClass("pop_selection_hide").bind("click",function(){_obj.showDlg(_this)});
					_obj.edit_style(_this);////初始化样式*/
			});
			this.hide();
		}
	})(jQuery);
		   
});//15901121834